package com.hulu73.spring.jdbc;

import java.sql.ResultSet;
import java.sql.SQLException;

public class UserRowMapper implements RowMapper<User>{

	@Override
	public User mapRow(ResultSet rs, int rowNum) throws SQLException {
		 User user = new User();
		 user.setId(rs.getInt("id"));
		 user.setName(rs.getString("name"));
		 user.setAge(rs.getInt("age"));
		 return user;
	}

	

}
